import React from 'react'
import {Switch} from "antd";
import {useModel} from "@@/exports";

const SwitchDark = () => {
    const {setIsDayOrNight} = useModel('userDayOrNightModel')
    return (
        <Switch
            className="dark"
            checkedChildren={<>🌞</>}
            unCheckedChildren={<>🌜</>}
            onChange={(status)=>{setIsDayOrNight(status)}}
        />
    )
}
export default SwitchDark
